package com.cooper.service.item;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.cooper.dao.item.LikeDetailDAO;
import com.cooper.entity.LikeDetailEntity;

/**
 * 点赞 详情
* @Description: 
* @version: v1.0.0
* @author: tianlg
* @date: Mar 12, 2015 9:14:06 PM
*
* Modification History:
* Date         Author          Version            Description
*---------------------------------------------------------*
* Mar 12, 2015      tianlg          v1.0.0
 */
@Service
public class LikeDetailService {
	
	@Autowired
	private LikeDetailDAO likeDetailDao;
	
	public Long saveEntity(LikeDetailEntity entity) throws Exception{
		return this.likeDetailDao.saveEntity(entity);
	}
	
	public void updateEntity(LikeDetailEntity entity) throws Exception{
		likeDetailDao.updateEntity(entity);
	}
	
	public LikeDetailEntity getEntityByClientIp(String origin, Long outerId, String clientIp) throws Exception{
		return this.likeDetailDao.getEntityByClientIp(origin, outerId, clientIp);
	}
	
	public LikeDetailEntity getEntityByUserId(String origin, Long outerId, Long userId) throws Exception{
		return this.likeDetailDao.getEntityByUserId(origin, outerId, userId);
	}

}
